import request from '@/utils/request'
export default {
  //登录
  submitLogin(userInfo) {
    return request({
      url: `/userservice/member/login`,
      method: 'post',
      data: userInfo
    })
  },
  //根据token获取用户信息npm install js-cookie
  getLoginInfo() {
    return request({
      url: `/userservice/member/auth/getLoginInfo`,
      method: 'get',
      // headers: {'token': cookie.get('guli_token')}
    })
    //headers: {'token': cookie.get('guli_token')}
  },

  updateInfo(userInfo){
    return request({
      url: `/userservice/member/auth/updateInfo`,
      method: 'post',
      data: userInfo
    })
  },

  updatePassword(password) {
    return request({
      url: `/userservice/member/update/password`,
      method: 'post',
      data: password
    })
  },

  getMenber(input){
    return request({
      url: `/userservice/member/getMenber/`+input,
      method: 'get',
    })
  },

  AddMeList(id){
    return request({
      url: `/userservice/friends/addFriend/`+id,
      method: 'get',
    })
  },
}
